/*
 * Created on 09/30/2011 - 11:15 AM
 */
package sembr.geometry.interfacing;

import importadorDXF.DxfEntity;
import sembr.geometry.utils.ColorMap;

/**
 *
 * @author Adriano
 */
public class ShapeBase<T extends DxfEntity> extends Shape<T>
{
    public ShapeBase()
    {}  
    
    @Override
    public int[] getColor(int index) 
    {
        short colorId = getCurrentElement(index).getColor();  
        
        // no color specified
        // set white color
        if (colorId == -1) colorId = 0;
                
        return ColorMap.getColor(colorId);        
    }  
}
